package com.quasar.hpatient.bean.home_medicine_record;

import android.text.TextUtils;

import java.util.List;

public final class MedicineRecoedBean {

    private List<MedicineRecoedItemBean> datas = null;

    public List<MedicineRecoedItemBean> getDatas() {
        return datas;
    }

    public void setDatas(List<MedicineRecoedItemBean> datas) {
        this.datas = datas;
    }

    public final static class MedicineRecoedItemBean {

        private String prescription_date = "";
        private MedicineRecoedContentBean json_record = null;
        private List<MedicineRecoedSimpleContentBean> json_simple_content = null;

        public String getPrescription_date() {
            return prescription_date;
        }

        public void setPrescription_date(String prescription_date) {
            this.prescription_date = prescription_date;
        }

        public MedicineRecoedContentBean getJson_record() {
            return json_record;
        }

        public void setJson_record(MedicineRecoedContentBean json_record) {
            this.json_record = json_record;
        }

        public List<MedicineRecoedSimpleContentBean> getJson_simple_content() {
            return json_simple_content;
        }

        public void setJson_simple_content(List<MedicineRecoedSimpleContentBean> json_simple_content) {
            this.json_simple_content = json_simple_content;
        }

        public final static class MedicineRecoedSimpleContentBean {

            private String mname = "";
            private String dose = "";

            public String getMname() {
                return mname;
            }

            public void setMname(String mname) {
                this.mname = mname;
            }

            public String getDose() {
                return dose;
            }

            public void setDose(String dose) {
                this.dose = dose;
            }
        }

        public final static class MedicineRecoedContentBean {

            private long editorid;
            private int editortype;
            private String hospital="";
            private String editcontent;
            private String editname = "";
            private String edittime = "";

            public String getHospital() {
                return hospital;
            }

            public void setHospital(String hospital) {
                this.hospital = hospital;
            }

            public CharSequence getEditcontent() {
                return editcontent;
            }

            public void setEditcontent(String editcontent) {
                this.editcontent = editcontent;
            }

            public String getEditname() {
                return editname;
            }

            public void setEditname(String editname) {
                this.editname = editname;
            }

            public long getEditorid() {
                return editorid;
            }

            public void setEditorid(long editorid) {
                this.editorid = editorid;
            }

            public int getEditortype() {
                return editortype;
            }

            public void setEditortype(int editortype) {
                this.editortype = editortype;
            }

            public String getEdittime() {

                if (TextUtils.isEmpty(edittime)) {
                    return "未知时间";
                } else if (edittime.length() >= 16) {
                    return edittime.substring(0, 16);
                } else {
                    return edittime;
                }
            }

            public void setEdittime(String edittime) {
                this.edittime = edittime;
            }

            @Override
            public String toString() {
                return "MedicineRecoedContentBean{" +
                        "editorid=" + editorid +
                        ", editortype=" + editortype +
                        ", editcontent=" + editcontent +
                        ", editname='" + editname + '\'' +
                        ", edittime='" + edittime + '\'' +
                        '}';
            }
        }
    }
}
